﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using PiscoSourPersistencia;
using PiscoSourDominio;


namespace PiscoSourRESTServices
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "Clientes" in code, svc and config file together.
    public class Clientes : IClientes
    {
        private ClienteDAO dao = new ClienteDAO();


        public Cliente ObtieneUsuarioCliente(String usuario, String pass)
        {
            return dao.ObtenerClienteUsuario(usuario, pass);
        }

        public Cliente ObtenerCliente(int codigo)
        {
            return dao.ObtenerCliente(codigo);
        }

        public List<Cliente> ListaClientes()
        {
            return dao.ListarClientes().ToList();
        }

        public List<Cliente> ListaClientesInactivos()
        {
            return dao.ListarClientesInactivos().ToList();
        }

        public Cliente ValidarLogin(string login, string pass) 
        {
            return dao.ValidarLogin(login, pass);
        }

    }
}
